=over

=item return EXPR
X<return>

=item return

Returns from a subroutine, L<C<eval>|/eval EXPR>,
L<C<do FILE>|/do EXPR>, L<C<sort>|/sort SUBNAME LIST> block or regex
eval block (but not a L<C<grep>|/grep BLOCK LIST>,
L<C<map>|/map BLOCK LIST>, or L<C<do BLOCK>|/do BLOCK> block) with the value
given in EXPR.  Evaluation of EXPR may be in list, scalar, or void
context, depending on how the return value will be used, and the context
may vary from one execution to the next (see
L<C<wantarray>|/wantarray>).  If no EXPR
is given, returns an empty list in list context, the undefined value in
scalar context, and (of course) nothing at all in void context.

(In the absence of an explicit L<C<return>|/return EXPR>, a subroutine,
L<C<eval>|/eval EXPR>,
or L<C<do FILE>|/do EXPR> automatically returns the value of the last expression
evaluated.)

Unlike most named operators, this is also exempt from the
looks-like-a-function rule, so C<return ("foo")."bar"> will
cause C<"bar"> to be part of the argument to L<C<return>|/return EXPR>.

=back